<!DOCTYPE html>
<html lang="zh-CN">

<head>
    <meta charset="UTF-8">
    <script type="text/javascript" src="../assets/js/vue.js"></script>
    <title>v-if & v-else & v-show</title>
</head>

<body>
    <h1>v-if & v-else & v-show 实例</h1>
    <hr>
    <div id="app">
        <div v-if="isLogin">你好,Link!</div>
        <div v-else>你好,请登录!</div>
    </div>
    <script type="text/javascript">
        var app = new Vue({
            el: '#app',
            data: {
                isLogin: true,
                isPass: false
            }
        })
    </script>
</body>

</html>